From: Thiemo Kreuz Date: Mon, 16 Apr 2018 17:30:07 +0000 (+0200) Subject: Fix bad archive file names in ImportableUploadRevisionImporter X-Git-Tag: 1.31.0-rc.0~37 X-Git-Url: http://git.cyclocoop.org/data/%27%20.%20mediabox_timestamp%28find_in_path%28%27javascript/%7B%24www_url%7Dadmin/compta/operations/%40%20%27info_etape_suivante_2%27%20=%3E%20%27You%20can%20move%20on%20to%20the%20next%20step.%27%2C%20%27info_exceptions_proxy%27%20=%3E%20%27Exceptions%20for%20the%20proxy%27%2C%20%27info_exportation_base%27%20=%3E%20%27export%20database%20to%20%40archive%40%27%2C-%27info_facilite_suivi_activite%27%20=%3E%20%27To%20simplify%20monitoring%20of%20the%20site/%27s%20editorial;-%20%20activities%2C%20SPIP%20can%20send%20rmail%20notifications%2C%20e.g.%20to%20an%20editors/%7B%24www_url%7D%7B%24page.uri%7Cescape%7D?a=commitdiff_plain;h=847143ae343cb08d7f350104a53e8c069ee171cc;p=lhc%2Fweb%2Fwiklou.git Fix bad archive file names in ImportableUploadRevisionImporter Bug: T176871 Change-Id: I61625a515a8d49dec33af49022506be2e019a23b (cherry picked from commit f449e1ce7c0f4092f8cb39e5a54489387ae35d45) --- diff --git a/includes/import/ImportableUploadRevisionImporter.php b/includes/import/ImportableUploadRevisionImporter.php index 495b3d60b3..b64114cf87 100644 --- a/includes/import/ImportableUploadRevisionImporter.php +++ b/includes/import/ImportableUploadRevisionImporter.php @@ -50,7 +50,7 @@ class ImportableUploadRevisionImporter implements UploadRevisionImporter { $file->load( File::READ_LATEST ); $this->logger->debug( __METHOD__ . 'Importing new file as ' . $file->getName() . "\n" ); if ( $file->exists() && $file->getTimestamp() > $importableRevision->getTimestamp() ) { - $archiveName = $file->getTimestamp() . '!' . $file->getName(); + $archiveName = $importableRevision->getTimestamp() . '!' . $file->getName(); $file = OldLocalFile::newFromArchiveName( $importableRevision->getTitle(), RepoGroup::singleton()->getLocalRepo(), $archiveName ); $this->logger->debug( __METHOD__ . "File already exists; importing as $archiveName\n" );